package com.github.codemperor.core.rsa;

/**
 * 私钥公钥父类
 *
 * @author codemperor
 */
public class BaseKey {
    /**
     * 公钥
     */
    public String publicKey;
    /**
     * 私钥
     */
    public String privateKey;

    public String getPublicKey() {
        return publicKey;
    }

    public void setPublicKey(String publicKey) {
        this.publicKey = publicKey;
    }

    public String getPrivateKey() {
        return privateKey;
    }

    public void setPrivateKey(String privateKey) {
        this.privateKey = privateKey;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("{");
        sb.append("\"publicKey\":\"")
                .append(publicKey).append('\"');
        sb.append(",\"privateKey\":\"")
                .append(privateKey).append('\"');
        sb.append('}');
        return sb.toString();
    }
}
